//CWE-1280 Consider the example Locked_override_register example. 
/*
Assume that the module foo_bar implements a protected register. 
The register content is the asset. Only transactions made by user id (indicated by signal usr_id) 0x4 are allowed to modify the register contents. 
The signal grant_access is used to provide access.
*/
module user_grant_access(data_out, usr_id, data_in, clk, rst_n);
output reg [7:0] data_out;
input wire [2:0] usr_id;
input wire [7:0] data_in;
input wire clk, rst_n;
reg grant_access;
always @ (posedge clk or negedge rst_n)
begin
if (!rst_n)
data_out = 0;
else begin
// data_out = (grant_access) ? data_in : data_out;
// grant_access = (usr_id == 3'h4) ? 1'b1 : 1'b0;
grant_access = (usr_id == 3'h4) ? 1'b1 : 1'b0;
data_out = (grant_access) ? data_in : data_out;
end
end
initial assume(~rst_n);
always @ (posedge clk)begin
    if($past(rst_n) && rst_n && $past(usr_id) == 3'h4)begin
        assert(data_out == $past(data_in));
    end
end
endmodule